package logic;

public class ScoreElement implements Comparable<ScoreElement>{
	
	public String name;
	public Double value;
	
	public ScoreElement(String name, Double value) {
		super();
		this.name = name;
		this.value = value;
	}
	
	public ScoreElement(String name){
		this(name, 0.0);
	}

	@Override
	public int compareTo(ScoreElement o) {
		return Double.compare(this.value, o.value) * -1;
	}
	
	public String toString() {
		return value + " " + name;
	}
	
}
